"use strict";

var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.uploadProps = exports.uploadListProps = exports.UploadFileStatus = exports.ShowUploadListInterface = void 0;

var _type = require("../_util/type");

var _vueTypes = _interopRequireDefault(require("../_util/vue-types"));

var UploadFileStatus = _vueTypes.default.oneOf((0, _type.tuple)('error', 'success', 'done', 'uploading', 'removed'));

exports.UploadFileStatus = UploadFileStatus;

var ShowUploadListInterface = _vueTypes.default.shape({
  showRemoveIcon: _vueTypes.default.looseBool,
  showPreviewIcon: _vueTypes.default.looseBool
}).loose;

exports.ShowUploadListInterface = ShowUploadListInterface;
var uploadProps = {
  type: _vueTypes.default.oneOf((0, _type.tuple)('drag', 'select')),
  name: _vueTypes.default.string,
  defaultFileList: {
    type: Array
  },
  fileList: {
    type: Array
  },
  action: _vueTypes.default.oneOfType([_vueTypes.default.string, _vueTypes.default.func]),
  directory: _vueTypes.default.looseBool,
  data: _vueTypes.default.oneOfType([_vueTypes.default.object, _vueTypes.default.func]),
  method: _vueTypes.default.oneOf((0, _type.tuple)('POST', 'PUT', 'PATCH', 'post', 'put', 'patch')),
  headers: _vueTypes.default.object,
  showUploadList: _vueTypes.default.oneOfType([_vueTypes.default.looseBool, ShowUploadListInterface]),
  multiple: _vueTypes.default.looseBool,
  accept: _vueTypes.default.string,
  beforeUpload: _vueTypes.default.func,
  listType: _vueTypes.default.oneOf((0, _type.tuple)('text', 'picture', 'picture-card')),
  // className: PropsTypes.string,
  remove: _vueTypes.default.func,
  supportServerRender: _vueTypes.default.looseBool,
  // style: PropsTypes.object,
  disabled: _vueTypes.default.looseBool,
  prefixCls: _vueTypes.default.string,
  customRequest: _vueTypes.default.func,
  withCredentials: _vueTypes.default.looseBool,
  openFileDialogOnClick: _vueTypes.default.looseBool,
  locale: {
    type: Object
  },
  height: _vueTypes.default.number,
  id: _vueTypes.default.string,
  previewFile: _vueTypes.default.func,
  transformFile: _vueTypes.default.func,
  onChange: {
    type: Function
  },
  onPreview: {
    type: Function
  },
  onRemove: {
    type: Function
  },
  onDownload: {
    type: Function
  },
  'onUpdate:fileList': {
    type: Function
  }
};
exports.uploadProps = uploadProps;
var uploadListProps = {
  listType: _vueTypes.default.oneOf((0, _type.tuple)('text', 'picture', 'picture-card')),
  // items: PropsTypes.arrayOf(UploadFile),
  items: {
    type: Array
  },
  progressAttr: _vueTypes.default.object,
  prefixCls: _vueTypes.default.string,
  showRemoveIcon: _vueTypes.default.looseBool,
  showDownloadIcon: _vueTypes.default.looseBool,
  showPreviewIcon: _vueTypes.default.looseBool,
  locale: {
    type: Object
  },
  previewFile: _vueTypes.default.func,
  onPreview: {
    type: Function
  },
  onRemove: {
    type: Function
  },
  onDownload: {
    type: Function
  }
};
exports.uploadListProps = uploadListProps;